import React, { Component } from 'react';
import { Grid } from 'antd-mobile';

import { HotCateBox } from '@/views/Home/style'
class Hotcate extends Component {
    render() {
        return (
            <HotCateBox>
                <div>热门分类</div>
                <Grid
                    data={this.props.cates}
                    activeStyle={false}
                    columnNum={4}
                    itemStyle={{ height: 50 }}
                    renderItem={({ title }) => (
                        <div onClick={() => this.props.history.push('/hot/' + title)}>{title}</div>
                    )}
                />
            </HotCateBox>
        );
    }
}

export default Hotcate;

